<?php

declare(strict_types=1);
/**
 * This file is part of habo_new_media.
 *
 * @link     https://www.berlen.cn/
 * @contact  tech@berlen.cn
 * @license  http://gitlab.rehou.cn/habo/habo_new_media/-/blob/master/README.md
 */
namespace app\service;

use app\model\ClientAccountModel;
use think\Model;

interface MediaTokenInterface
{
//    public static function refreshToken(MediaTokenModel $model);
    /**
     * 根据refresh_token刷新token.
     * @param string $appId app_id
     * @param string $appSecret secret
     * @param string $refreshToken refreshToken
     * @return bool|mixed
     */
    public static function refreshToken(string $appId = '', string $appSecret = '', string $refreshToken = '');
    public static function refreshAdv(Model $obj, ClientAccountModel $account);

    /**
     * 获取接口账户信息.
     * @param int $accountId 账户id
     * @param string $token token值
     * @return bool
     */
    public static function getAccountInfo(int $accountId = 0, string $token = ''): bool;

}
